
<template>
	<login-modal ref="mlogin" :getUsers="getUsers"></login-modal>
</template>

<script>
	export default {
		data(){
			return {
				
			}
		},
		onLaunch: function() {
			
			uni.login({
			    success:res=>{
			        uni.setStorageSync("logincode",res.code);
					
			    },
			    fail:err=>{
			        uni.setStorageSync("logincode",'');
			    }
			})


			// 判断用户是否登录

			uni.getSystemInfo({
			  success: (res) => {
				  	
					let _H = res.platform == 'ios' ? 44 : 48;
					let topPx = res.statusBarHeight + _H
					this.globalData.height = res.statusBarHeight;
					this.globalData.screenWidth = res.screenWidth
					uni.setStorageSync('dpr',res.devicePixelRatio)
					uni.setStorageSync('screenWidth',res.screenWidth)
					this.setNavHeight(topPx)
			    }
			})
		},
		onLoad(options){
			if(options.ref_id){
				this.changeRefId(options.ref_id)
			}
		},
		onHide: function() {
		},
		globalData: {
		    share: false,  // 分享默认为false
		    height: 0,
			screenWidth:0
		},
		watch:{
			changeToggle_show(v){
				
			}
		}
	}
</script>

<style lang="scss">
		
	page{
		width:100%;
		min-height: 100vh;
		
	}
	/*每个页面公共css */


	@import './styles/common.css';
	@import './styles/top.css';
	@import './styles/animate.css';
	
	@import './wxcomponents/vant/dist/common/index.wxss';
	.tada{
		animation: tada 1.3s both infinite;
	}
	.heartBeat{
		animation: heartBeat 3s 0 ;
	}

	.bounce{
		animation: bounce 1.3s  both infinite;
	}

	.pulse{
		animation: pulse 1.3s  both infinite;
	}

	
	
</style>
